
package Structural.Flyweight;

/**
 *
 * @author Demoni
 */ 
public class Test{
public static void main(String[] args) {

        
        Flyweight recurso = Factory.dameRecurso("/var/www/index.html");
        recurso.loggearHit("200.51.211.7");
        
        recurso = Factory.dameRecurso("/var/www/index.html");
        recurso.loggearHit("192.168.1.8");
        
        recurso = Factory.dameRecurso("/var/www/search.html");
        recurso.loggearHit("192.168.1.8");
        
        recurso = Factory.dameRecurso("/var/www/search.html");
        recurso.loggearHit("192.1.1.8");
        
        recurso = Factory.dameRecurso("/var/www/search.html");
        recurso.loggearHit("192.2.11.8");
        
        Factory.mostrarEstadisticas();
    }

}
